package com.cpos.orderserver.service.Impl;

import com.cpos.orderserver.mapper.OrderMapper;
import com.cpos.orderserver.service.OrderService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
@Service
public class OrderServiceImpl implements OrderService {

//    @Autowired
//    private OrderMapper mapper;

    @Override
    public List<Map<Object, Object>> OrderToStock(String goodId) {
        List<Map<Object, Object>> mapList = new ArrayList<>();
        Map<Object, Object> map = new HashMap<>();
        Map<Object, Object> map2 = new HashMap<>();

        try {
            map.put("订单号","12AZT8819QE91");
            map.put("订单金额","5121.89");

            map2.put("商家名称","湖南大运责任有限公司");
            map2.put("商品名称","微星H13U-1980Ti笔记本电脑");

            mapList.add(map);
            mapList.add(map2);
        } catch (Exception e) {
            e.printStackTrace();
        }
        return mapList;
    }
}
